html_files=""
for f in *.html; do if [ "$f" != "*.html" ]; then html_files="$html_files $f"; fi; done

if [ "`echo $html_files | wc | awk '{ print $2 }'`" != "0" ]; then
  to_revert=`svn diff $html_files | diffstat | awk '$3 == "2" { print $1 }'`
  if [ "`echo $to_revert | wc | awk '{ print $2 }'`" != "0" ]; then
    svn revert $to_revert
  fi
fi
